#ifndef CH_LISTVIEW_H
#define CH_LISTVIEW_H

#pragma once

#include "CHListCtrl.h"

class AFX_EXT_CLASS CHListView : public CListView, public CHListCtrlBase
{
    DECLARE_DYNCREATE(CHListView)

public:
    
    // Constructs a CHListView object.
    //
    CHListView();

    // Destroys a CHListView object, handles cleanup and de-allocation.
    //
    virtual ~CHListView();


    // This member function is called to set extended styles for the 
    // list control ie: LVS_EX_FULLROWSELECT, LVS_EX_GRIDLINES, etc.
    virtual void SetExtendedStyle(
        // Specifies the LVS_EX_ style to set.
        DWORD dwExStyle );

    // This member function is called to return the list control 
    // extended style.
    DWORD GetExtendedStyle();

protected:

public:
    
    //{{AFX_VIRTUAL(CHListView)
    public:
    virtual void OnInitialUpdate();
    protected:
    virtual void OnDraw(CDC* pDC);      // overridden to draw this view
    virtual BOOL OnNotify(WPARAM wParam, LPARAM lParam, LRESULT* pResult);
    //}}AFX_VIRTUAL

#ifdef _DEBUG
    virtual void AssertValid() const;
    virtual void Dump(CDumpContext& dc) const;
#endif

    //{{AFX_MSG(CHListView)
    afx_msg void OnCustomDraw(NMHDR* pNMHDR, LRESULT* pResult);
    afx_msg void OnDestroy();
    afx_msg BOOL OnEraseBkgnd(CDC* pDC);
    afx_msg void OnPaint();
    afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
    afx_msg void OnSettingChange(UINT uFlags, LPCTSTR lpszSection);
    //}}AFX_MSG
    //:End Ignore
    DECLARE_MESSAGE_MAP()
};

/////////////////////////////////////////////////////////////////////////////

AFX_INLINE DWORD CHListView::GetExtendedStyle() {
	return CHListCtrlBase::GetExtendedStyle();
}
AFX_INLINE void CHListView::SetExtendedStyle(DWORD dwExStyle){
	CHListCtrlBase::SetExtendedStyle(dwExStyle);
}


#endif //CH_LISTVIEW_H
